package com.xiaochong.tir.api.controller.hc;

import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;

import java.util.Map;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;

import com.xiaochong.tir.api.service.hc.ApiHcResult;
import com.xiaochong.tir.api.service.hc.HcService;
import com.xiaochong.tir.api.util.ApiVersion;

/**
 * 算立方币价查询
 * @author qzw
 * 2018年10月24日 下午2:26:02
 * @description 
 **/
@Api(value="算立方接口")
@RestController
@RequestMapping(ApiVersion.API_V1_PREFIX+"/tir/hc/currency")
public class HcController {
	
	@Autowired
	private HcService hcService;

	@ApiOperation(value = "算立方币价接口", notes = "返回code：00-成功；01-参数错误；02-失败；")
	@PostMapping("/getCurrencyPrice")
	public ApiHcResult<Map<String, String>> getCurrencyPrice(@RequestParam String cmcId){
		ApiHcResult<Map<String, String>> api = hcService.getCurrencyPrice(cmcId);
		return api;
	}
}
